import type {
  getHotSearchRes,
  getSearchSuggestParams,
  getSearchSuggestRes,
  keyWordRes,
} from "@/types/search";
import request from "@/utils/request";
export const getDefaultSearchKeyWord = () => {
  return request<keyWordRes>({
    method: "get",
    url: "/search/default",
  });
};
export const getHotSearch = () => {
  return request<getHotSearchRes>({
    method: "get",
    url: "/search/hot/detail",
  });
};
export const getSearchSuggest = (params: getSearchSuggestParams) => {
  return request<getSearchSuggestRes>({
    method: "get",
    url: "/search/suggest",
    params,
  });
};
